package com.mars.basic.allmain.vo;

import com.mars.basic.allmain.entity.AdminRoleEntity;
import com.mars.basic.allmain.po.AdminRole;
import com.mars.common.utils.Beans;
import lombok.Data;

import java.util.Date;

@Data
public class AdminRoleVo {
    Integer roleId;

    Integer adminUserId;


    public AdminRoleEntity build(){
        AdminRole adminRole = AdminRole.builder().adminId(adminUserId)
                .roleId(roleId)
                .createTime(new Date())
                .updateTime(new Date())
                .build();
        return Beans.mapper(adminRole,AdminRoleEntity.class);
    }

}
